<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <title>表单的自动提交</title>
    <script type="text/javascript">
        function method01(){
            alert('提交执行 ');
            return true;      //判断是否执行默认
        }
    </script>
</head>
<body>
<form action="js02_01_01.html" method="post" onsubmit="return method01()">
    用户名：<input type="text"><br>
    密&nbsp;&nbsp;&nbsp;码：<input type="password"><br>
    <input type="submit" value="提交">
    <input type="reset" value="重置">

</form>
</body>
</html>